import Qt 4.7

Rectangle {
    width: 640
    height: 360

    Loader {
        id: mainViewLoader
        anchors.fill: parent
        onLoaded: {
            splash.opacity = 0
            item.canvasWidth = 580
            item.canvasHeight = height
        }
    }

    Image {
        id: splash
        anchors.fill: parent
        source: "gfx/splashscreen.png"

        Timer {
            interval: 1000
            running: true
            repeat: false
            onTriggered: {
                mainViewLoader.source = "MainView.qml"
            }
        }
        Behavior on opacity { NumberAnimation {duration: 1000; easing.type: Easing.InOutCubic}}
    }
}
